package com.car.dal.dao.source;

import java.util.List;

import com.car.bean.GridObj;
import com.car.bean.OrderObj;
import com.car.bean.PageObj;
import com.car.dal.dao.ibatis.IbatisCommonDao;
import com.car.dal.object.TgReserve;
import com.car.dal.object.TgSource;

public class TgSourceDaoImpl extends IbatisCommonDao<TgSource, Long> implements TgSourceDao {

	public GridObj GetList(TgSource source, PageObj pageObj) {
		OrderObj order = new OrderObj();
		order.setDir("desc");
		order.setSort("id");
		return super.findByPage(source, pageObj, order);
	}

	@Override
	public List<TgSource> findBySouName(TgSource source) {
		List<TgSource> list=this.queryForEntityList(TgSource.class,"getBySouName", source);
		return list;
	}

	@Override
	public List<TgSource> getAll() {
		List<TgSource> list=this.queryForEntityList(TgSource.class,"getAllSource", null);
		return list;
	}

}
